#include "TurnManager.h"
#include "StaticTurnManager.h"
#include "DynamicTurnManager.h"

TurnManager* TurnManager :: createTurnManager(const string& type) throw (InvalidTurnManager) {
	if (type == "Statico 1") {
		return new StaticTurnManager(1);
	}
	else if (type == "Statico 2") {
		return new StaticTurnManager(2);
	}
	else if (type == "Statico 3") {
		return new StaticTurnManager(3);
	}
	else if (type == "Statico 4") {
		return new StaticTurnManager(4);
	}
	else if (type == "Statico 5") {
		return new StaticTurnManager(5);
	}
	else if (type == "Statico 6") {
		return new StaticTurnManager(6);
	}
	else if (type == "Statico 7") {
		return new StaticTurnManager(7);
	}
	else if (type == "Statico 8") {
		return new StaticTurnManager(8);
	}
	else if (type == "Statico 9") {
		return new StaticTurnManager(9);
	}
	else if (type == "Dinamico") {
		return new DynamicTurnManager();
	}
	else {
		throw InvalidTurnManager();
	}
}
